﻿#region License

// Copyright (c) 2009, Bill O'Neill (william.w.oneill@gmail.com)
// All rights reserved.
// 
// Redistribution and use in source and binary forms, with or without 
// modification, are permitted provided that the following conditions 
// are met:
// 
// 1. Redistributions of source code must retain the above copyright 
// notice, this list of conditions and the following disclaimer.
// 
// 2. Redistributions in binary form must reproduce the above copyright 
// notice, this list of conditions and the following disclaimer in the 
// documentation and/or other materials provided with the distribution.
// 
// 3. Neither the name of Focal Point Technology Solutions, LLC nor 
// the names of its contributors may be used to endorse or promote 
// products derived from this software without specific prior written 
// permission.
// 
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND 
// CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, 
// INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 
// MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 
// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR 
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 
// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED 
// TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, 
// OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE 
// USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH 
// DAMAGE.

#endregion

namespace X10d.Interface
{
	/// <summary>
	/// X10 House codes
	/// </summary>
	public enum HouseCodeType : byte
	{
		A = 0x60,
		B = 0xE0,
		C = 0x20,
		D = 0xA0,
		E = 0x10,
		F = 0x90,
		G = 0x50,
		H = 0xD0,
		I = 0x70,
		J = 0xF0,
		K = 0x30,
		L = 0xB0,
		M = 0x00,
		N = 0x80,
		O = 0x40,
		P = 0xC0
	}

	/// <summary>
	/// X10 Device codes
	/// </summary>
	public enum DeviceCodeType : byte
	{
		One = 0x06,
		Two = 0x0E,
		Three = 0x02,
		Four = 0x0A,
		Five = 0x01,
		Six = 0x09,
		Seven = 0x05,
		Eight = 0x0D,
		Nine = 0x07,
		Ten = 0x0F,
		Eleven = 0x03,
		Twelve = 0x0B,
		Thirteen = 0x00,
		Fourteen = 0x08,
		Fifteen = 0x04,
		Sixteen = 0x0C,
	}

	/// <summary>
	/// X10 function codes
	/// </summary>
	public enum FunctionCodeType : byte
	{
		AllUnitsOff = 0x00,
		AllLightsOn = 0x01,
		On = 0x02,
		Off = 0x03,
		Dim = 0x04,
		Bright = 0x05,
		AllLightsOff = 0x06,
		ExtendedCode = 0x07,
		HailRequest = 0x08,
		HailAcknowledge = 0x09,
		PreSetDim1 = 0x0A,
		PreSetDim2 = 0x0B,
		ExtendedDataTransfer = 0x0C,
		StatusOn = 0x0D,
		StatusOff = 0x0E,
		StatusRequest = 0x0F
	}
}